package samsung.sds.business.vdiManagementSystem.vdiManagement.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import samsung.sds.business.vdiManagementSystem.vdiManagement.dao.VDIHistoryMapper;
import samsung.sds.business.vdiManagementSystem.vdiManagement.model.VdiHistoryEntity;
import samsung.sds.business.vdiManagementSystem.vdiManagement.service.VdiHistoryService;
import samsung.sds.system.common.baseQuery.AbstractBaseService;
import samsung.sds.system.common.baseQuery.BaseMapper;
import samsung.sds.system.common.model.QueryParam;

/**
 * @author tongwei.li
 * @createDate 2016-04-27
 * 
 *             vdi 历史service implemention
 */
@Service
public class VdiHistoryServiceImpl extends
		AbstractBaseService<VdiHistoryEntity> implements VdiHistoryService {

	@Autowired
	private VDIHistoryMapper vdiHistoryMapper;

	/**
	 * query list by id and content implementation
	 * 
	 * @param param
	 * @return
	 */
	@Override
	public List<VdiHistoryEntity> queryListPageByIdAndContent(QueryParam param) {
		return vdiHistoryMapper.queryListPageByIdAndContent(param);
	}

	@Override
	protected BaseMapper<VdiHistoryEntity> getMapper() {
		return vdiHistoryMapper;
	}

	/**
	 * insert into entity implementation
	 * 
	 * @param entity
	 * @return
	 */
	@Override
	public int insertHistoryEntity(VdiHistoryEntity entity) {

		return vdiHistoryMapper.insertHistoryEntity(entity);
	}

}
